<!DOCTYPE html>
<html lang="zh-CN">
<head>
  <meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=2">
<meta name="theme-color" content="#222">
<meta name="generator" content="Hexo 4.2.0">
  <link rel="apple-touch-icon" sizes="180x180" href="/images/apple-touch-icon-next.png">
  <link rel="icon" type="image/png" sizes="32x32" href="/images/favicon-32x32-next.png">
  <link rel="icon" type="image/png" sizes="16x16" href="/images/favicon-16x16-next.png">
  <link rel="mask-icon" href="/images/logo.svg" color="#222">

<link rel="stylesheet" href="/css/main.css">


<link rel="stylesheet" href="/lib/font-awesome/css/all.min.css">

<script id="hexo-configurations">
    var NexT = window.NexT || {};
    var CONFIG = {"hostname":"gongxicheng.cn","root":"/","scheme":"Gemini","version":"7.8.0","exturl":false,"sidebar":{"position":"left","display":"post","padding":18,"offset":12,"onmobile":false},"copycode":{"enable":false,"show_result":false,"style":null},"back2top":{"enable":true,"sidebar":false,"scrollpercent":false},"bookmark":{"enable":false,"color":"#222","save":"auto"},"fancybox":false,"mediumzoom":false,"lazyload":false,"pangu":false,"comments":{"style":"tabs","active":null,"storage":true,"lazyload":false,"nav":null},"algolia":{"hits":{"per_page":10},"labels":{"input_placeholder":"Search for Posts","hits_empty":"We didn't find any results for the search: ${query}","hits_stats":"${hits} results found in ${time} ms"}},"localsearch":{"enable":false,"trigger":"auto","top_n_per_article":1,"unescape":false,"preload":false},"motion":{"enable":true,"async":false,"transition":{"post_block":"fadeIn","post_header":"slideDownIn","post_body":"slideDownIn","coll_header":"slideLeftIn","sidebar":"slideUpIn"}}};
  </script>

  <meta property="og:type" content="website">
<meta property="og:title" content="恭喜">
<meta property="og:url" content="gongxicheng.cn/page/2/index.html">
<meta property="og:site_name" content="恭喜">
<meta property="og:locale" content="zh_CN">
<meta property="article:author" content="Gary Gong">
<meta name="twitter:card" content="summary">

<link rel="canonical" href="gongxicheng.cn/page/2/">


<script id="page-configurations">
  // https://hexo.io/docs/variables.html
  CONFIG.page = {
    sidebar: "",
    isHome : true,
    isPost : false,
    lang   : 'zh-CN'
  };
</script>

  <title>恭喜</title>
  
    <script async src="https://www.googletagmanager.com/gtag/js?id=UA-123017381-1"></script>
    <script>
      if (CONFIG.hostname === location.hostname) {
        window.dataLayer = window.dataLayer || [];
        function gtag(){dataLayer.push(arguments);}
        gtag('js', new Date());
        gtag('config', 'UA-123017381-1');
      }
    </script>






  <noscript>
  <style>
  .use-motion .brand,
  .use-motion .menu-item,
  .sidebar-inner,
  .use-motion .post-block,
  .use-motion .pagination,
  .use-motion .comments,
  .use-motion .post-header,
  .use-motion .post-body,
  .use-motion .collection-header { opacity: initial; }

  .use-motion .site-title,
  .use-motion .site-subtitle {
    opacity: initial;
    top: initial;
  }

  .use-motion .logo-line-before i { left: initial; }
  .use-motion .logo-line-after i { right: initial; }
  </style>
</noscript>

</head>

<body itemscope itemtype="http://schema.org/WebPage">
  <div class="container use-motion">
    <div class="headband"></div>

    <header class="header" itemscope itemtype="http://schema.org/WPHeader">
      <div class="header-inner"><div class="site-brand-container">
  <div class="site-nav-toggle">
    <div class="toggle" aria-label="切换导航栏">
      <span class="toggle-line toggle-line-first"></span>
      <span class="toggle-line toggle-line-middle"></span>
      <span class="toggle-line toggle-line-last"></span>
    </div>
  </div>

  <div class="site-meta">

    <a href="/" class="brand" rel="start">
      <span class="logo-line-before"><i></i></span>
      <h1 class="site-title">恭喜</h1>
      <span class="logo-line-after"><i></i></span>
    </a>
  </div>

  <div class="site-nav-right">
    <div class="toggle popup-trigger">
    </div>
  </div>
</div>




<nav class="site-nav">
  <ul id="menu" class="main-menu menu">
        <li class="menu-item menu-item-home">

    <a href="/" rel="section"><i class="fa fa-home fa-fw"></i>首页</a>

  </li>
        <li class="menu-item menu-item-about">

    <a href="/about/" rel="section"><i class="fa fa-user fa-fw"></i>关于</a>

  </li>
        <li class="menu-item menu-item-tags">

    <a href="/tags/" rel="section"><i class="fa fa-tags fa-fw"></i>标签</a>

  </li>
        <li class="menu-item menu-item-categories">

    <a href="/categories/" rel="section"><i class="fa fa-th fa-fw"></i>分类</a>

  </li>
        <li class="menu-item menu-item-archives">

    <a href="/archives/" rel="section"><i class="fa fa-archive fa-fw"></i>归档</a>

  </li>
  </ul>
</nav>




</div>
    </header>

    
  <div class="back-to-top">
    <i class="fa fa-arrow-up"></i>
    <span>0%</span>
  </div>


    <main class="main">
      <div class="main-inner">
        <div class="content-wrap">
          

          <div class="content index posts-expand">
            
      
  
  
  <article itemscope itemtype="http://schema.org/Article" class="post-block" lang="zh-CN">
    <link itemprop="mainEntityOfPage" href="gongxicheng.cn/2020/01/02/before2020/2020-01-02-markdown-help/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="image" content="/images/avatar.gif">
      <meta itemprop="name" content="Gary Gong">
      <meta itemprop="description" content="">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="恭喜">
    </span>
      <header class="post-header">
        <h2 class="post-title" itemprop="name headline">
          
            <a href="/2020/01/02/before2020/2020-01-02-markdown-help/" class="post-title-link" itemprop="url">Markdwon 语法</a>
        </h2>

        <div class="post-meta">
            <span class="post-meta-item">
              <span class="post-meta-item-icon">
                <i class="far fa-calendar"></i>
              </span>
              <span class="post-meta-item-text">发表于</span>

              <time title="创建时间：2020-01-02 10:34:05" itemprop="dateCreated datePublished" datetime="2020-01-02T10:34:05+00:00">2020-01-02</time>
            </span>
              <span class="post-meta-item">
                <span class="post-meta-item-icon">
                  <i class="far fa-calendar-check"></i>
                </span>
                <span class="post-meta-item-text">更新于</span>
                <time title="修改时间：2020-12-03 05:23:42" itemprop="dateModified" datetime="2020-12-03T05:23:42+00:00">2020-12-03</time>
              </span>

          

        </div>
      </header>

    
    
    
    <div class="post-body" itemprop="articleBody">

      
          <p>复制了 cmd MarkDown的语法说明。删除不支持的</p>
<h3 id="1-标题"><a href="#1-标题" class="headerlink" title="1. 标题"></a>1. 标题</h3><p>使用 === 表示一级标题，使用 — 表示二级标题。</p>
<p>示例：</p>
<figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br></pre></td><td class="code"><pre><span class="line">这是一个一级标题</span><br><span class="line">&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;&#x3D;</span><br><span class="line"></span><br><span class="line">这是一个二级标题</span><br><span class="line">--------------------------------------------------</span><br><span class="line"></span><br><span class="line">### 这是一个三级标题</span><br></pre></td></tr></table></figure>

<p>你也可以选择在行首加井号表示不同级别的标题 (H1-H6)，例如：# H1, ## H2, ### H3，#### H4。</p>
<h3 id="2-文本样式"><a href="#2-文本样式" class="headerlink" title="2. 文本样式"></a>2. 文本样式</h3><p>Markdown支持4中文本样式，分别是：加粗、斜体、删除线和加粗且斜体。</p>
<table>
<thead>
<tr>
<th>样式</th>
<th>关键字</th>
<th>快捷键</th>
<th>样例</th>
<th>输出</th>
</tr>
</thead>
<tbody><tr>
<td>加粗</td>
<td>** **或者__ __</td>
<td>command/control+b</td>
<td><code>**加粗文本**</code></td>
<td>加粗文本</td>
</tr>
<tr>
<td>斜体</td>
<td>* *或者_ _</td>
<td>command/control+i</td>
<td><code>_斜体文本_</code></td>
<td>斜体文本</td>
</tr>
<tr>
<td>删除线</td>
<td><del>~ ~</del></td>
<td>无</td>
<td><code>~~删除线~~</code></td>
<td>删除线</td>
</tr>
<tr>
<td>加粗且斜体</td>
<td>** **和_ _</td>
<td>无</td>
<td><code>**这个是：_加粗且斜体_**</code></td>
<td><strong>_这个是_加粗且斜体</strong></td>
</tr>
</tbody></table>
<h3 id="3-外链接"><a href="#3-外链接" class="headerlink" title="3. 外链接"></a>3. 外链接</h3><p>使用 [描述](链接地址) 为文字增加外链接。</p>
<p>示例：</p>
<p>这是去往 <a href="http://ghosertblog.github.com" target="_blank" rel="noopener">本人博客</a> 的链接。</p>
<h3 id="4-无序列表"><a href="#4-无序列表" class="headerlink" title="4. 无序列表"></a>4. 无序列表</h3><p>使用 *，+，- 表示无序列表。</p>
<p>示例：</p>
<ul>
<li>无序列表项 一</li>
<li>无序列表项 二</li>
<li>无序列表项 三</li>
</ul>
<h3 id="5-有序列表"><a href="#5-有序列表" class="headerlink" title="5. 有序列表"></a>5. 有序列表</h3><p>使用数字和点表示有序列表。</p>
<p>示例：</p>
<ol>
<li>有序列表项 一</li>
<li>有序列表项 二</li>
<li>有序列表项 三</li>
</ol>
<h3 id="6-文字引用"><a href="#6-文字引用" class="headerlink" title="6. 文字引用"></a>6. 文字引用</h3><p>使用 &gt; 表示文字引用。</p>
<p>示例：</p>
<blockquote>
<p>野火烧不尽，春风吹又生。</p>
</blockquote>
<h3 id="7-行内代码块"><a href="#7-行内代码块" class="headerlink" title="7. 行内代码块"></a>7. 行内代码块</h3><p>使用 `代码` 表示行内代码块。</p>
<p>示例：</p>
<p>让我们聊聊 <code>html</code>。</p>
<h3 id="8-代码块"><a href="#8-代码块" class="headerlink" title="8.  代码块"></a>8.  代码块</h3><p>使用 四个缩进空格 表示代码块。</p>
<p>示例：</p>
<pre><code>这是一个代码块，此行左侧有四个不可见的空格。</code></pre><h3 id="9-插入图像"><a href="#9-插入图像" class="headerlink" title="9.  插入图像"></a>9.  插入图像</h3><p>使用 ![描述](图片链接地址) 插入图像。</p>
<p>示例：</p>
<p><img src="https://www.zybuluo.com/static/img/my_head.jpg" alt="我的头像"></p>
<h3 id="2-标签分类"><a href="#2-标签分类" class="headerlink" title="2. 标签分类"></a>2. 标签分类</h3><p>在编辑区任意行的列首位置输入以下代码给文稿标签：</p>
<p>标签： 数学 英语 Markdown</p>
<p>或者</p>
<p>Tags： 数学 英语 Markdown</p>
<h3 id="3-删除线"><a href="#3-删除线" class="headerlink" title="3. 删除线"></a>3. 删除线</h3><p>使用 ~~ 表示删除线。</p>
<p><del>这是一段错误的文本。</del></p>
<h3 id="6-加强的代码块"><a href="#6-加强的代码块" class="headerlink" title="6. 加强的代码块"></a>6. 加强的代码块</h3><p>支持四十一种编程语言的语法高亮的显示，行号显示。</p>
<p>非代码示例：</p>
<figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">$ sudo apt-get install vim-gnome</span><br></pre></td></tr></table></figure>

<p>Python 示例：</p>
<figure class="highlight python"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br></pre></td><td class="code"><pre><span class="line"><span class="meta">@requires_authorization</span></span><br><span class="line"><span class="function"><span class="keyword">def</span> <span class="title">somefunc</span><span class="params">(param1=<span class="string">''</span>, param2=<span class="number">0</span>)</span>:</span></span><br><span class="line">    <span class="string">'''A docstring'''</span></span><br><span class="line">    <span class="keyword">if</span> param1 &gt; param2: <span class="comment"># interesting</span></span><br><span class="line">        <span class="keyword">print</span> <span class="string">'Greater'</span></span><br><span class="line">    <span class="keyword">return</span> (param2 - param1 + <span class="number">1</span>) <span class="keyword">or</span> <span class="literal">None</span></span><br><span class="line"></span><br><span class="line"><span class="class"><span class="keyword">class</span> <span class="title">SomeClass</span>:</span></span><br><span class="line">    <span class="keyword">pass</span></span><br><span class="line"></span><br><span class="line"><span class="meta">&gt;&gt;&gt; </span>message = <span class="string">'''interpreter</span></span><br><span class="line"><span class="string"><span class="meta">... </span>prompt'''</span></span><br></pre></td></tr></table></figure>

<p>JavaScript 示例：</p>
<figure class="highlight javascript"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br><span class="line">16</span><br><span class="line">17</span><br></pre></td><td class="code"><pre><span class="line"><span class="comment">/**</span></span><br><span class="line"><span class="comment">* nth element in the fibonacci series.</span></span><br><span class="line"><span class="comment">* <span class="doctag">@param </span>n &gt;= 0</span></span><br><span class="line"><span class="comment">* <span class="doctag">@return </span>the nth element, &gt;= 0.</span></span><br><span class="line"><span class="comment">*/</span></span><br><span class="line"><span class="function"><span class="keyword">function</span> <span class="title">fib</span>(<span class="params">n</span>) </span>&#123;</span><br><span class="line">  <span class="keyword">var</span> a = <span class="number">1</span>, b = <span class="number">1</span>;</span><br><span class="line">  <span class="keyword">var</span> tmp;</span><br><span class="line">  <span class="keyword">while</span> (--n &gt;= <span class="number">0</span>) &#123;</span><br><span class="line">    tmp = a;</span><br><span class="line">    a += b;</span><br><span class="line">    b = tmp;</span><br><span class="line">  &#125;</span><br><span class="line">  <span class="keyword">return</span> a;</span><br><span class="line">&#125;</span><br><span class="line"></span><br><span class="line"><span class="built_in">document</span>.write(fib(<span class="number">10</span>));</span><br></pre></td></tr></table></figure>


<h3 id="12-表格支持"><a href="#12-表格支持" class="headerlink" title="12. 表格支持"></a>12. 表格支持</h3><table>
<thead>
<tr>
<th>项目</th>
<th align="right">价格</th>
<th align="center">数量</th>
</tr>
</thead>
<tbody><tr>
<td>计算机</td>
<td align="right">$1600</td>
<td align="center">5</td>
</tr>
<tr>
<td>手机</td>
<td align="right">$12</td>
<td align="center">12</td>
</tr>
<tr>
<td>管线</td>
<td align="right">$1</td>
<td align="center">234</td>
</tr>
</tbody></table>
<h3 id="14-Html-标签"><a href="#14-Html-标签" class="headerlink" title="14. Html 标签"></a>14. Html 标签</h3><p>本站支持在 Markdown 语法中嵌套 Html 标签，譬如，你可以用 Html 写一个纵跨两行的表格：</p>
<pre><code>&lt;table&gt;
    &lt;tr&gt;
        &lt;th rowspan=&quot;2&quot;&gt;值班人员&lt;/th&gt;
        &lt;th&gt;星期一&lt;/th&gt;
        &lt;th&gt;星期二&lt;/th&gt;
        &lt;th&gt;星期三&lt;/th&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
        &lt;td&gt;李强&lt;/td&gt;
        &lt;td&gt;张明&lt;/td&gt;
        &lt;td&gt;王平&lt;/td&gt;
    &lt;/tr&gt;
&lt;/table&gt;</code></pre><table>
    <tr>
        <th rowspan="2">值班人员</th>
        <th>星期一</th>
        <th>星期二</th>
        <th>星期三</th>
    </tr>
    <tr>
        <td>李强</td>
        <td>张明</td>
        <td>王平</td>
    </tr>
</table>


<h3 id="16-待办事宜-Todo-列表"><a href="#16-待办事宜-Todo-列表" class="headerlink" title="16. 待办事宜 Todo 列表"></a>16. 待办事宜 Todo 列表</h3><p>使用带有 [ ] 或 [x] （未完成或已完成）项的列表语法撰写一个待办事宜列表，并且支持子列表嵌套以及混用Markdown语法，例如：</p>
<pre><code>- [ ] **Cmd Markdown 开发**
    - [ ] 改进 Cmd 渲染算法，使用局部渲染技术提高渲染效率
    - [ ] 支持以 PDF 格式导出文稿
    - [x] 新增Todo列表功能 [语法参考](https://github.com/blog/1375-task-lists-in-gfm-issues-pulls-comments)
    - [x] 改进 LaTex 功能
        - [x] 修复 LaTex 公式渲染问题
        - [x] 新增 LaTex 公式编号功能 [语法参考](http://docs.mathjax.org/en/latest/tex.html#tex-eq-numbers)
- [ ] **七月旅行准备**
    - [ ] 准备邮轮上需要携带的物品
    - [ ] 浏览日本免税店的物品
    - [x] 购买蓝宝石公主号七月一日的船票</code></pre><p>对应显示如下待办事宜 Todo 列表：</p>
<ul>
<li><input disabled="" type="checkbox"> <strong>Cmd Markdown 开发</strong><ul>
<li><input disabled="" type="checkbox"> 改进 Cmd 渲染算法，使用局部渲染技术提高渲染效率</li>
<li><input disabled="" type="checkbox"> 支持以 PDF 格式导出文稿</li>
<li><input checked="" disabled="" type="checkbox"> 新增Todo列表功能 <a href="https://github.com/blog/1375-task-lists-in-gfm-issues-pulls-comments" target="_blank" rel="noopener">语法参考</a></li>
<li><input checked="" disabled="" type="checkbox"> 改进 LaTex 功能<ul>
<li><input checked="" disabled="" type="checkbox"> 修复 LaTex 公式渲染问题</li>
<li><input checked="" disabled="" type="checkbox"> 新增 LaTex 公式编号功能 <a href="http://docs.mathjax.org/en/latest/tex.html#tex-eq-numbers" target="_blank" rel="noopener">语法参考</a></li>
</ul>
</li>
</ul>
</li>
<li><input disabled="" type="checkbox"> <strong>七月旅行准备</strong><ul>
<li><input disabled="" type="checkbox"> 准备邮轮上需要携带的物品</li>
<li><input disabled="" type="checkbox"> 浏览日本免税店的物品</li>
<li><input checked="" disabled="" type="checkbox"> 购买蓝宝石公主号七月一日的船票</li>
</ul>
</li>
</ul>

      
    </div>

    
    
    
      <footer class="post-footer">
        <div class="post-eof"></div>
      </footer>
  </article>
  
  
  

      
  
  
  <article itemscope itemtype="http://schema.org/Article" class="post-block" lang="zh-CN">
    <link itemprop="mainEntityOfPage" href="gongxicheng.cn/2020/01/02/before2020/2020-01-02-tkinter-combobox/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="image" content="/images/avatar.gif">
      <meta itemprop="name" content="Gary Gong">
      <meta itemprop="description" content="">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="恭喜">
    </span>
      <header class="post-header">
        <h2 class="post-title" itemprop="name headline">
          
            <a href="/2020/01/02/before2020/2020-01-02-tkinter-combobox/" class="post-title-link" itemprop="url">Python Tkinter  Combobox</a>
        </h2>

        <div class="post-meta">
            <span class="post-meta-item">
              <span class="post-meta-item-icon">
                <i class="far fa-calendar"></i>
              </span>
              <span class="post-meta-item-text">发表于</span>

              <time title="创建时间：2020-01-02 10:34:05" itemprop="dateCreated datePublished" datetime="2020-01-02T10:34:05+00:00">2020-01-02</time>
            </span>
              <span class="post-meta-item">
                <span class="post-meta-item-icon">
                  <i class="far fa-calendar-check"></i>
                </span>
                <span class="post-meta-item-text">更新于</span>
                <time title="修改时间：2020-12-03 05:23:42" itemprop="dateModified" datetime="2020-12-03T05:23:42+00:00">2020-12-03</time>
              </span>

          

        </div>
      </header>

    
    
    
    <div class="post-body" itemprop="articleBody">

      
          <p>###基础</p>
<p><code>Combobox</code> 包含在 ‘ttk’ 中，所以需要先引入 ttk</p>
<p>Combobox 支持的属性：</p>
<ul>
<li>values 或者 value :</li>
<li>state : readonly </li>
<li>current: 选中的内容</li>
<li>ComboboxSelected ：绑定的选择事件</li>
</ul>
<figure class="highlight python"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br><span class="line">16</span><br><span class="line">17</span><br><span class="line">18</span><br><span class="line">19</span><br><span class="line">20</span><br><span class="line">21</span><br><span class="line">22</span><br><span class="line">23</span><br><span class="line">24</span><br><span class="line">25</span><br><span class="line">26</span><br><span class="line">27</span><br><span class="line">28</span><br><span class="line">29</span><br><span class="line">30</span><br><span class="line">31</span><br><span class="line">32</span><br><span class="line">33</span><br><span class="line">34</span><br></pre></td><td class="code"><pre><span class="line"><span class="keyword">import</span> tkinter</span><br><span class="line"><span class="keyword">from</span> tkinter <span class="keyword">import</span> ttk <span class="comment"># 导入ttk模块，因为下拉菜单控件在ttk中</span></span><br><span class="line"></span><br><span class="line">root = tkinter.Tk()</span><br><span class="line">root.title(<span class="string">"root"</span>)</span><br><span class="line">root.geometry(<span class="string">"300x200+10+20"</span>)</span><br><span class="line"></span><br><span class="line">xVar = tkinter.StringVar()</span><br><span class="line"></span><br><span class="line"><span class="comment"># 创建下拉菜单</span></span><br><span class="line">cmb = ttk.Combobox(root,textvariable=xVar)</span><br><span class="line">cmb.pack(side=tkinter.TOP)</span><br><span class="line"></span><br><span class="line"><span class="comment"># 设置下拉菜单中的值</span></span><br><span class="line">cmb[<span class="string">'value'</span>] = (<span class="string">'上海'</span>,<span class="string">'北京'</span>,<span class="string">'天津'</span>,<span class="string">'广州'</span>)</span><br><span class="line"></span><br><span class="line"><span class="comment"># 设置默认值，即默认下拉框中的内容 默认值中的内容为索引，从0开始</span></span><br><span class="line">cmb.current(<span class="number">2</span>)</span><br><span class="line"></span><br><span class="line"><span class="comment"># 执行函数</span></span><br><span class="line"><span class="function"><span class="keyword">def</span> <span class="title">func</span><span class="params">(event)</span>:</span></span><br><span class="line">    lVar.set(<span class="string">'label1'</span>+cmb.get())</span><br><span class="line">    label2.config(text=<span class="string">'label2'</span>+xVar.get())</span><br><span class="line">cmb.bind(<span class="string">"&lt;&lt;ComboboxSelected&gt;&gt;"</span>,func)</span><br><span class="line"></span><br><span class="line">lVar = tkinter.StringVar()</span><br><span class="line"></span><br><span class="line">label1 = tkinter.Label(root,textvariable=lVar,)</span><br><span class="line">label1.pack(side=tkinter.TOP)</span><br><span class="line"></span><br><span class="line">label2 = tkinter.Label(root,bg=<span class="string">'green'</span>)</span><br><span class="line">label2.pack(side=tkinter.TOP)</span><br><span class="line"></span><br><span class="line">root.mainloop()</span><br></pre></td></tr></table></figure>


<figure class="highlight python"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br></pre></td><td class="code"><pre><span class="line"></span><br><span class="line"></span><br></pre></td></tr></table></figure>

      
    </div>

    
    
    
      <footer class="post-footer">
        <div class="post-eof"></div>
      </footer>
  </article>
  
  
  

      
  
  
  <article itemscope itemtype="http://schema.org/Article" class="post-block" lang="zh-CN">
    <link itemprop="mainEntityOfPage" href="gongxicheng.cn/2019/09/01/before2020/2019-09-01-banwagong-install-shadowsockets/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="image" content="/images/avatar.gif">
      <meta itemprop="name" content="Gary Gong">
      <meta itemprop="description" content="">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="恭喜">
    </span>
      <header class="post-header">
        <h2 class="post-title" itemprop="name headline">
          
            <a href="/2019/09/01/before2020/2019-09-01-banwagong-install-shadowsockets/" class="post-title-link" itemprop="url">Banwagong 自己配置shadowsockets</a>
        </h2>

        <div class="post-meta">
            <span class="post-meta-item">
              <span class="post-meta-item-icon">
                <i class="far fa-calendar"></i>
              </span>
              <span class="post-meta-item-text">发表于</span>

              <time title="创建时间：2019-09-01 17:51:05" itemprop="dateCreated datePublished" datetime="2019-09-01T17:51:05+00:00">2019-09-01</time>
            </span>
              <span class="post-meta-item">
                <span class="post-meta-item-icon">
                  <i class="far fa-calendar-check"></i>
                </span>
                <span class="post-meta-item-text">更新于</span>
                <time title="修改时间：2020-12-03 05:23:42" itemprop="dateModified" datetime="2020-12-03T05:23:42+00:00">2020-12-03</time>
              </span>

          

        </div>
      </header>

    
    
    
    <div class="post-body" itemprop="articleBody">

      
          <p>这个是转载的文章，但是我在配置的过程中遇到了几个问题，都在此记录一下，防止之后自己又记不住了。(以前总以为自己能记住几个特殊的步骤，回头发现之后俄都是自欺欺人啊)</p>
<p><a href="https://baijifeilong.github.io/2018/12/10/bandwagon/" target="_blank" rel="noopener">原文地址</a><br>原文内容也贴过来，备用啊。</p>
<h2 id="原文对我有用的"><a href="#原文对我有用的" class="headerlink" title="原文对我有用的"></a>原文对我有用的</h2><p>三、服务器机房选择<br>洛杉矶机房二选一（DC2 QNET、DC4 MCOM）。DC4为搬瓦工新加机房。<br>实际体验上半斤八两。<br>加拿大、荷兰机房最好不要选择。<br>根据概率论，美国与赵国的网络连接基数大，IP被封杀的机率低</p>
<p>四、服务器购买<br>支付宝购买即可。美刀自动换算为人民币</p>
<p>有6.25趴优惠码(BWH26FXH3HIQ)可用。优惠码来自网络，有效期不详。可省1.25美刀，最终需支付18.74美刀</p>
<p>五、服务器系统选择<br>默认系统是 Centos 6 x86 bbr。</p>
<p>BBR是谷歌出品的拥塞控制算法，据说优化网速有奇效</p>
<p>建议换为Centos 7 x86_64 bbr。Centos 6 太老，官方包的python只支持到2.6。没有Systemd服务管理工具</p>
<p>六、Shadowsocks服务安装</p>
<ol>
<li>安装Shadowsocks<br>yum install -y epel-release 安装Centos社区仓库，pip与sodium在里头<br>yum install -y python2-pip libsodium git pip和git用来安装Shadowsocks libsodium用于支持chacha20加密算法<br>pip install git+<a href="https://github.com/shadowsocks/shadowsocks.git@master" target="_blank" rel="noopener">https://github.com/shadowsocks/shadowsocks.git@master</a> 从Shadowsocks官方Git仓库的主分支下载Shadowsocks源码并安装</li>
<li>添加Shadowsocks为Systemd服务<br>创建并填充 /usr/lib/systemd/system/myss.service<figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br></pre></td><td class="code"><pre><span class="line">[Unit]</span><br><span class="line">Description&#x3D;My shadowsocks server</span><br><span class="line"></span><br><span class="line">[Service]</span><br><span class="line">ExecStart&#x3D;&#x2F;usr&#x2F;bin&#x2F;ssserver -k password -m chacha20 -p 33333</span><br></pre></td></tr></table></figure></li>
<li>启动Shadowsocks服务<br>systemctl start myss 启动服务<br>systemctl status myss 查看服务运行状态<br>stop 停止服务 restart 重启服务<br>七、Shadowsocks的使用</li>
<li>运行本地代理服务<br>sslocal -s <SERVER-HOST> -k password -m chacha20 -p 33333 -l 44444</li>
</ol>
<p>Shadowsocks会开启一个SOCKS5本地代理。</p>
<p>端口最好更改一下，减小被封杀机率</p>
<p>加密方法建议选择chacha20，CPU负载低，给搬瓦工公司节省几分钱电费</p>
<ol start="2">
<li>测试代理是否工作<br>curl –socks5-host localhost:44444 <a href="http://www.google" target="_blank" rel="noopener">www.google</a>.</li>
</ol>
<h2 id="补充1"><a href="#补充1" class="headerlink" title="补充1"></a>补充1</h2><p>使用mac的termanil可以直接进行ssh的链接。<br>命令：</p>
<figure class="highlight bash"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">ssh root@**.**.**.** -p 26556</span><br></pre></td></tr></table></figure>
<p>接下来输入密码即可<br>这个比网页上自带的bash页面好很多，也能直接编辑文件什么的</p>
<h2 id="补充2"><a href="#补充2" class="headerlink" title="补充2"></a>补充2</h2><p>执行 安装Shadowsocks 中的安装源和pip的时候，会提示已经安装，但是安装pip的时候依然提示找不到包，原因是默认禁用了epel，所以需要我们开启这个源。<br>搜到大多数的方法都是编辑文件，当时不会用term 进行ssh链接，所以找到了这个命令行修改的方式</p>
<figure class="highlight bash"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">yum-config-manager --<span class="built_in">enable</span> remi</span><br></pre></td></tr></table></figure>
<h2 id="补充3"><a href="#补充3" class="headerlink" title="补充3"></a>补充3</h2><p>创建的命令<br>    usr/lib/systemd/system/myss.service</p>
<p>vim 内的保存推出是 wq。</p>
<h2 id="补充4"><a href="#补充4" class="headerlink" title="补充4"></a>补充4</h2><p>第一次设置完成后不好用，不知道端口不对还是其他参数有问题，所以使用了之前的配置可以正常使用了。下回配置的时候注意</p>

      
    </div>

    
    
    
      <footer class="post-footer">
        <div class="post-eof"></div>
      </footer>
  </article>
  
  
  

      
  
  
  <article itemscope itemtype="http://schema.org/Article" class="post-block" lang="zh-CN">
    <link itemprop="mainEntityOfPage" href="gongxicheng.cn/2019/04/08/before2020/2019-04-08-Dotnet-core-docker-hello/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="image" content="/images/avatar.gif">
      <meta itemprop="name" content="Gary Gong">
      <meta itemprop="description" content="">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="恭喜">
    </span>
      <header class="post-header">
        <h2 class="post-title" itemprop="name headline">
          
            <a href="/2019/04/08/before2020/2019-04-08-Dotnet-core-docker-hello/" class="post-title-link" itemprop="url">.Net Core Docker Hello</a>
        </h2>

        <div class="post-meta">
            <span class="post-meta-item">
              <span class="post-meta-item-icon">
                <i class="far fa-calendar"></i>
              </span>
              <span class="post-meta-item-text">发表于</span>

              <time title="创建时间：2019-04-08 19:51:05" itemprop="dateCreated datePublished" datetime="2019-04-08T19:51:05+00:00">2019-04-08</time>
            </span>
              <span class="post-meta-item">
                <span class="post-meta-item-icon">
                  <i class="far fa-calendar-check"></i>
                </span>
                <span class="post-meta-item-text">更新于</span>
                <time title="修改时间：2020-12-03 05:23:42" itemprop="dateModified" datetime="2020-12-03T05:23:42+00:00">2020-12-03</time>
              </span>

          

        </div>
      </header>

    
    
    
    <div class="post-body" itemprop="articleBody">

      
          <h2 id="创建-Console-App"><a href="#创建-Console-App" class="headerlink" title="创建 Console App"></a>创建 Console App</h2><p>创建文件夹 DockerHello ,在 term 执行命令</p>
<figure class="highlight bash"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br></pre></td><td class="code"><pre><span class="line">dotnet new console</span><br><span class="line">dotnet run</span><br></pre></td></tr></table></figure>

<h2 id="容器化-Net-Core-程序"><a href="#容器化-Net-Core-程序" class="headerlink" title="容器化 .Net Core 程序"></a>容器化 .Net Core 程序</h2><h3 id="第一个-Dockerfile"><a href="#第一个-Dockerfile" class="headerlink" title="第一个 Dockerfile"></a>第一个 Dockerfile</h3><p>创建没有后缀的的 Dockerfile</p>
<figure class="highlight bash"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br></pre></td><td class="code"><pre><span class="line">FROM microsoft/dotnet:2.1-sdk</span><br><span class="line">WORKDIR /app</span><br><span class="line"></span><br><span class="line"><span class="comment"># copy csproj and restore as distinct layers</span></span><br><span class="line">COPY *.csproj ./</span><br><span class="line">RUN dotnet restore</span><br><span class="line"></span><br><span class="line"><span class="comment"># copy and build everything else</span></span><br><span class="line">COPY . ./</span><br><span class="line">RUN dotnet publish -c Release -o out</span><br><span class="line">ENTRYPOINT [<span class="string">"dotnet"</span>, <span class="string">"out/DockerHello.dll"</span>]</span><br><span class="line">`</span><br></pre></td></tr></table></figure>

<h3 id="build-and-run"><a href="#build-and-run" class="headerlink" title="build and run"></a>build and run</h3><p>分别执行以下两个命令，分别是创建 image 和运行 image</p>
<figure class="highlight bash"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br></pre></td><td class="code"><pre><span class="line">docker build -t dotnetapp-dev .</span><br><span class="line">docker run --rm dotnetapp-dev Hello from Docker</span><br></pre></td></tr></table></figure>
      
    </div>

    
    
    
      <footer class="post-footer">
        <div class="post-eof"></div>
      </footer>
  </article>
  
  
  

      
  
  
  <article itemscope itemtype="http://schema.org/Article" class="post-block" lang="zh-CN">
    <link itemprop="mainEntityOfPage" href="gongxicheng.cn/2019/04/08/before2020/2019-04-08-list-to-dictionary/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="image" content="/images/avatar.gif">
      <meta itemprop="name" content="Gary Gong">
      <meta itemprop="description" content="">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="恭喜">
    </span>
      <header class="post-header">
        <h2 class="post-title" itemprop="name headline">
          
            <a href="/2019/04/08/before2020/2019-04-08-list-to-dictionary/" class="post-title-link" itemprop="url">c# List to Dictionary</a>
        </h2>

        <div class="post-meta">
            <span class="post-meta-item">
              <span class="post-meta-item-icon">
                <i class="far fa-calendar"></i>
              </span>
              <span class="post-meta-item-text">发表于</span>

              <time title="创建时间：2019-04-08 17:51:05" itemprop="dateCreated datePublished" datetime="2019-04-08T17:51:05+00:00">2019-04-08</time>
            </span>
              <span class="post-meta-item">
                <span class="post-meta-item-icon">
                  <i class="far fa-calendar-check"></i>
                </span>
                <span class="post-meta-item-text">更新于</span>
                <time title="修改时间：2020-12-03 05:23:42" itemprop="dateModified" datetime="2020-12-03T05:23:42+00:00">2020-12-03</time>
              </span>

          

        </div>
      </header>

    
    
    
    <div class="post-body" itemprop="articleBody">

      
          <p>C#.NET 利用ToDictionary()，GroupBy()，可以将List转化为Dictionary，主需要一行代码！</p>
<p>首先看一下需求，已知cars，等于：</p>
<figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br></pre></td><td class="code"><pre><span class="line">List&lt;Car&gt; cars &#x3D; new List&lt;Car&gt;()&#123;</span><br><span class="line">                new Car(1,&quot;audiA6&quot;,&quot;private&quot;),</span><br><span class="line">                new Car(2,&quot;futon&quot;,&quot;merchant&quot;),</span><br><span class="line">                new Car(3,&quot;feiren&quot;,&quot;bike&quot;),</span><br><span class="line">                new Car(4,&quot;bukon&quot;,&quot;private&quot;),</span><br><span class="line">                new Car(5,&quot;baoma&quot;,&quot;private&quot;),</span><br><span class="line">                new Car(6,&quot;dayun&quot;,&quot;merchant&quot;)</span><br><span class="line">            &#125;;</span><br></pre></td></tr></table></figure>
<p>1）我想以id为键，值为Car转化为一个字典idCarDict，方法如下：</p>
<pre><code>var idCarDict = cars.ToDictionary(car=&gt;car.id);</code></pre><p>这样保证能正确转化的前提为，id在列表中没有重复值。如果有重复的，会抛出向字典中添加重复值的异常。</p>
<p>2）我想以type为键，值car的List的typeDict，方法如下：</p>
<pre><code>Dictionary&lt;string, List&lt;Car&gt;&gt; typeCarDict = cars.GroupBy(car =&gt; car.type).ToDictionary(r =&gt; r.Key, r =&gt; r.ToList());</code></pre><p>分步解释：<br>第一步分组</p>
<pre><code>cars.GroupBy(car=&gt;car.type) //返回的结果类型为： //IEnumerable&lt;IGroup&lt;string,car&gt;&gt;;</code></pre><p>//其中string等于car.type，也就是分组的键<br>第二步将IEnumerable类型转化为字典，选取合适的键，</p>
<pre><code>ToDictionary(r=&gt;r.Key,r=&gt;r.ToList());</code></pre><p>//r参数代表分组对象，r.Key便是car.type;<br>//r.ToList()操作后将分组对象转化为List对象<br>这种转化代码简介，比以下foreach遍历得到以car.type的字典简洁许多：</p>
<figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br></pre></td><td class="code"><pre><span class="line">var dict &#x3D; new Dictionary&lt;string,List&lt;Car&gt;&gt;();</span><br><span class="line">foreach(var car in cars)</span><br><span class="line">&#123;</span><br><span class="line">  if(dict.Contains(car.type))</span><br><span class="line">     dict[car.type].Add(car);</span><br><span class="line">  else</span><br><span class="line">    dict.Add(car.type,new List&lt;Car&gt;()&#123;car&#125;));</span><br><span class="line">&#125;</span><br></pre></td></tr></table></figure>

<p>转的文章，希望自己能记住todictionary 的使用方法<br><a href="http://www.voidcn.com/article/p-cvbngeoz-p.html" target="_blank" rel="noopener">链接</a></p>

      
    </div>

    
    
    
      <footer class="post-footer">
        <div class="post-eof"></div>
      </footer>
  </article>
  
  
  

      
  
  
  <article itemscope itemtype="http://schema.org/Article" class="post-block" lang="zh-CN">
    <link itemprop="mainEntityOfPage" href="gongxicheng.cn/2019/03/27/before2020/2019-03-26-C-sharp-ConvertTimeToUtc-error/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="image" content="/images/avatar.gif">
      <meta itemprop="name" content="Gary Gong">
      <meta itemprop="description" content="">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="恭喜">
    </span>
      <header class="post-header">
        <h2 class="post-title" itemprop="name headline">
          
            <a href="/2019/03/27/before2020/2019-03-26-C-sharp-ConvertTimeToUtc-error/" class="post-title-link" itemprop="url">C# ConvertTimeToUtc error</a>
        </h2>

        <div class="post-meta">
            <span class="post-meta-item">
              <span class="post-meta-item-icon">
                <i class="far fa-calendar"></i>
              </span>
              <span class="post-meta-item-text">发表于</span>

              <time title="创建时间：2019-03-27 17:51:05" itemprop="dateCreated datePublished" datetime="2019-03-27T17:51:05+00:00">2019-03-27</time>
            </span>
              <span class="post-meta-item">
                <span class="post-meta-item-icon">
                  <i class="far fa-calendar-check"></i>
                </span>
                <span class="post-meta-item-text">更新于</span>
                <time title="修改时间：2020-12-03 05:23:42" itemprop="dateModified" datetime="2020-12-03T05:23:42+00:00">2020-12-03</time>
              </span>

          

        </div>
      </header>

    
    
    
    <div class="post-body" itemprop="articleBody">

      
          <p>记录下见过的error,<br>产品环境的代码不一样但是和这个运行的结果是一样的<br>ConvertTimeToUtc</p>
<figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br></pre></td><td class="code"><pre><span class="line">var tz &#x3D; TimeZoneInfo.FindSystemTimeZoneById(&quot;W. Europe Standard Time&quot;);</span><br><span class="line">var swedishTime &#x3D; TimeZoneInfo.ConvertTime(DateTime.UtcNow, tz);</span><br><span class="line"></span><br><span class="line">System.ArgumentException: The conversion could not be completed because the supplied DateTime did not have the Kind property set correctly.</span><br></pre></td></tr></table></figure>

<p>解决方式是 直接用了 new data(); 不适用utcnow</p>

      
    </div>

    
    
    
      <footer class="post-footer">
        <div class="post-eof"></div>
      </footer>
  </article>
  
  
  

      
  
  
  <article itemscope itemtype="http://schema.org/Article" class="post-block" lang="zh-CN">
    <link itemprop="mainEntityOfPage" href="gongxicheng.cn/2018/08/01/before2020/2018-08-01-csharp-indepth-1-The-changing-face-of-Cshapr-development/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="image" content="/images/avatar.gif">
      <meta itemprop="name" content="Gary Gong">
      <meta itemprop="description" content="">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="恭喜">
    </span>
      <header class="post-header">
        <h2 class="post-title" itemprop="name headline">
          
            <a href="/2018/08/01/before2020/2018-08-01-csharp-indepth-1-The-changing-face-of-Cshapr-development/" class="post-title-link" itemprop="url">C# 开发的进化史</a>
        </h2>

        <div class="post-meta">
            <span class="post-meta-item">
              <span class="post-meta-item-icon">
                <i class="far fa-calendar"></i>
              </span>
              <span class="post-meta-item-text">发表于</span>

              <time title="创建时间：2018-08-01 17:51:05" itemprop="dateCreated datePublished" datetime="2018-08-01T17:51:05+00:00">2018-08-01</time>
            </span>
              <span class="post-meta-item">
                <span class="post-meta-item-icon">
                  <i class="far fa-calendar-check"></i>
                </span>
                <span class="post-meta-item-text">更新于</span>
                <time title="修改时间：2020-12-03 05:23:42" itemprop="dateModified" datetime="2020-12-03T05:23:42+00:00">2020-12-03</time>
              </span>

          

        </div>
      </header>

    
    
    
    <div class="post-body" itemprop="articleBody">

      
          <h1 id="C-开发的进化史"><a href="#C-开发的进化史" class="headerlink" title="C# 开发的进化史"></a>C# 开发的进化史</h1><h1 id="从简单的数据类型开始"><a href="#从简单的数据类型开始" class="headerlink" title="从简单的数据类型开始"></a>从简单的数据类型开始</h1><h1 id="排序和过滤"><a href="#排序和过滤" class="headerlink" title="排序和过滤"></a>排序和过滤</h1><h1 id="处理未知数据"><a href="#处理未知数据" class="headerlink" title="处理未知数据"></a>处理未知数据</h1><h1 id="LINQ-简介"><a href="#LINQ-简介" class="headerlink" title="LINQ 简介"></a>LINQ 简介</h1><h1 id="COM和动态类"><a href="#COM和动态类" class="headerlink" title="COM和动态类"></a>COM和动态类</h1><h1 id="剖析-NET-平台"><a href="#剖析-NET-平台" class="headerlink" title="剖析.NET 平台"></a>剖析.NET 平台</h1>
      
    </div>

    
    
    
      <footer class="post-footer">
        <div class="post-eof"></div>
      </footer>
  </article>
  
  
  

      
  
  
  <article itemscope itemtype="http://schema.org/Article" class="post-block" lang="zh-CN">
    <link itemprop="mainEntityOfPage" href="gongxicheng.cn/2018/08/01/before2020/2018-08-01-csharp-indepth-2-Core-foundations-bounding-on-C1/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="image" content="/images/avatar.gif">
      <meta itemprop="name" content="Gary Gong">
      <meta itemprop="description" content="">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="恭喜">
    </span>
      <header class="post-header">
        <h2 class="post-title" itemprop="name headline">
          
            <a href="/2018/08/01/before2020/2018-08-01-csharp-indepth-2-Core-foundations-bounding-on-C1/" class="post-title-link" itemprop="url">C# 1 所搭建的核心基础</a>
        </h2>

        <div class="post-meta">
            <span class="post-meta-item">
              <span class="post-meta-item-icon">
                <i class="far fa-calendar"></i>
              </span>
              <span class="post-meta-item-text">发表于</span>

              <time title="创建时间：2018-08-01 17:51:05" itemprop="dateCreated datePublished" datetime="2018-08-01T17:51:05+00:00">2018-08-01</time>
            </span>
              <span class="post-meta-item">
                <span class="post-meta-item-icon">
                  <i class="far fa-calendar-check"></i>
                </span>
                <span class="post-meta-item-text">更新于</span>
                <time title="修改时间：2020-12-03 05:23:42" itemprop="dateModified" datetime="2020-12-03T05:23:42+00:00">2020-12-03</time>
              </span>

          

        </div>
      </header>

    
    
    
    <div class="post-body" itemprop="articleBody">

      
          <h1 id="C-委托"><a href="#C-委托" class="headerlink" title="C# 委托"></a>C# 委托</h1><h1 id="类型系统的特征"><a href="#类型系统的特征" class="headerlink" title="类型系统的特征"></a>类型系统的特征</h1><h1 id="值类型和引用类型"><a href="#值类型和引用类型" class="headerlink" title="值类型和引用类型"></a>值类型和引用类型</h1><h1 id="C-1-之外-构建于坚实基础之上的新特性"><a href="#C-1-之外-构建于坚实基础之上的新特性" class="headerlink" title="C# 1 之外:构建于坚实基础之上的新特性"></a>C# 1 之外:构建于坚实基础之上的新特性</h1>
      
    </div>

    
    
    
      <footer class="post-footer">
        <div class="post-eof"></div>
      </footer>
  </article>
  
  
  

      
  
  
  <article itemscope itemtype="http://schema.org/Article" class="post-block" lang="zh-CN">
    <link itemprop="mainEntityOfPage" href="gongxicheng.cn/2018/07/29/before2020/2018-07-25-serialization-and-deserialization/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="image" content="/images/avatar.gif">
      <meta itemprop="name" content="Gary Gong">
      <meta itemprop="description" content="">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="恭喜">
    </span>
      <header class="post-header">
        <h2 class="post-title" itemprop="name headline">
          
            <a href="/2018/07/29/before2020/2018-07-25-serialization-and-deserialization/" class="post-title-link" itemprop="url">serialization and deserialization</a>
        </h2>

        <div class="post-meta">
            <span class="post-meta-item">
              <span class="post-meta-item-icon">
                <i class="far fa-calendar"></i>
              </span>
              <span class="post-meta-item-text">发表于</span>

              <time title="创建时间：2018-07-29 17:17:43" itemprop="dateCreated datePublished" datetime="2018-07-29T17:17:43+00:00">2018-07-29</time>
            </span>
              <span class="post-meta-item">
                <span class="post-meta-item-icon">
                  <i class="far fa-calendar-check"></i>
                </span>
                <span class="post-meta-item-text">更新于</span>
                <time title="修改时间：2020-12-03 05:23:42" itemprop="dateModified" datetime="2020-12-03T05:23:42+00:00">2020-12-03</time>
              </span>

          

        </div>
      </header>

    
    
    
    <div class="post-body" itemprop="articleBody">

      
          <h1 id="序列化"><a href="#序列化" class="headerlink" title="序列化"></a>序列化</h1><h2 id="原理"><a href="#原理" class="headerlink" title="原理"></a>原理</h2><h2 id="使用"><a href="#使用" class="headerlink" title="使用"></a>使用</h2><h2 id="其他"><a href="#其他" class="headerlink" title="其他"></a>其他</h2>
      
    </div>

    
    
    
      <footer class="post-footer">
        <div class="post-eof"></div>
      </footer>
  </article>
  
  
  

      
  
  
  <article itemscope itemtype="http://schema.org/Article" class="post-block" lang="zh-CN">
    <link itemprop="mainEntityOfPage" href="gongxicheng.cn/2018/07/25/before2020/2018-07-25-C-sharp-box-and-unbox/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="image" content="/images/avatar.gif">
      <meta itemprop="name" content="Gary Gong">
      <meta itemprop="description" content="">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="恭喜">
    </span>
      <header class="post-header">
        <h2 class="post-title" itemprop="name headline">
          
            <a href="/2018/07/25/before2020/2018-07-25-C-sharp-box-and-unbox/" class="post-title-link" itemprop="url">C# 装箱与拆箱</a>
        </h2>

        <div class="post-meta">
            <span class="post-meta-item">
              <span class="post-meta-item-icon">
                <i class="far fa-calendar"></i>
              </span>
              <span class="post-meta-item-text">发表于</span>

              <time title="创建时间：2018-07-25 17:51:05" itemprop="dateCreated datePublished" datetime="2018-07-25T17:51:05+00:00">2018-07-25</time>
            </span>
              <span class="post-meta-item">
                <span class="post-meta-item-icon">
                  <i class="far fa-calendar-check"></i>
                </span>
                <span class="post-meta-item-text">更新于</span>
                <time title="修改时间：2020-12-03 05:23:42" itemprop="dateModified" datetime="2020-12-03T05:23:42+00:00">2020-12-03</time>
              </span>

          

        </div>
      </header>

    
    
    
    <div class="post-body" itemprop="articleBody">

      
          <h1 id="定义"><a href="#定义" class="headerlink" title="定义"></a>定义</h1><h2 id="我的问题"><a href="#我的问题" class="headerlink" title="我的问题"></a>我的问题</h2><h2 id="如何在编程中避免"><a href="#如何在编程中避免" class="headerlink" title="如何在编程中避免"></a>如何在编程中避免</h2><h2 id="查找到的相关博客的问题"><a href="#查找到的相关博客的问题" class="headerlink" title="查找到的相关博客的问题"></a>查找到的相关博客的问题</h2><h2 id="面试被问到答错的问题"><a href="#面试被问到答错的问题" class="headerlink" title="面试被问到答错的问题"></a>面试被问到答错的问题</h2><p>Q： Console.WriteLine(3); 是否发生了装箱</p>

      
    </div>

    
    
    
      <footer class="post-footer">
        <div class="post-eof"></div>
      </footer>
  </article>
  
  
  


  
  <nav class="pagination">
    <a class="extend prev" rel="prev" href="/"><i class="fa fa-angle-left" aria-label="上一页"></i></a><a class="page-number" href="/">1</a><span class="page-number current">2</span><a class="page-number" href="/page/3/">3</a><a class="page-number" href="/page/4/">4</a><a class="extend next" rel="next" href="/page/3/"><i class="fa fa-angle-right" aria-label="下一页"></i></a>
  </nav>



          </div>
          

<script>
  window.addEventListener('tabs:register', () => {
    let { activeClass } = CONFIG.comments;
    if (CONFIG.comments.storage) {
      activeClass = localStorage.getItem('comments_active') || activeClass;
    }
    if (activeClass) {
      let activeTab = document.querySelector(`a[href="#comment-${activeClass}"]`);
      if (activeTab) {
        activeTab.click();
      }
    }
  });
  if (CONFIG.comments.storage) {
    window.addEventListener('tabs:click', event => {
      if (!event.target.matches('.tabs-comment .tab-content .tab-pane')) return;
      let commentClass = event.target.classList[1];
      localStorage.setItem('comments_active', commentClass);
    });
  }
</script>

        </div>
          
  
  <div class="toggle sidebar-toggle">
    <span class="toggle-line toggle-line-first"></span>
    <span class="toggle-line toggle-line-middle"></span>
    <span class="toggle-line toggle-line-last"></span>
  </div>

  <aside class="sidebar">
    <div class="sidebar-inner">

      <ul class="sidebar-nav motion-element">
        <li class="sidebar-nav-toc">
          文章目录
        </li>
        <li class="sidebar-nav-overview">
          站点概览
        </li>
      </ul>

      <!--noindex-->
      <div class="post-toc-wrap sidebar-panel">
      </div>
      <!--/noindex-->

      <div class="site-overview-wrap sidebar-panel">
        <div class="site-author motion-element" itemprop="author" itemscope itemtype="http://schema.org/Person">
  <p class="site-author-name" itemprop="name">Gary Gong</p>
  <div class="site-description" itemprop="description"></div>
</div>
<div class="site-state-wrap motion-element">
  <nav class="site-state">
      <div class="site-state-item site-state-posts">
          <a href="/archives/">
        
          <span class="site-state-item-count">31</span>
          <span class="site-state-item-name">日志</span>
        </a>
      </div>
      <div class="site-state-item site-state-categories">
            <a href="/categories/">
          
        <span class="site-state-item-count">2</span>
        <span class="site-state-item-name">分类</span></a>
      </div>
      <div class="site-state-item site-state-tags">
            <a href="/tags/">
          
        <span class="site-state-item-count">17</span>
        <span class="site-state-item-name">标签</span></a>
      </div>
  </nav>
</div>
  <div class="links-of-author motion-element">
      <span class="links-of-author-item">
        <a href="https://github.com/darktutu" title="GitHub → https:&#x2F;&#x2F;github.com&#x2F;darktutu" rel="noopener" target="_blank"><i class="fab fa-github fa-fw"></i>GitHub</a>
      </span>
  </div>



      </div>

    </div>
  </aside>
  <div id="sidebar-dimmer"></div>


      </div>
    </main>

    <footer class="footer">
      <div class="footer-inner">
        

        

<div class="copyright">
  
  &copy; 
  <span itemprop="copyrightYear">2020</span>
  <span class="with-love">
    <i class="fa fa-heart"></i>
  </span>
  <span class="author" itemprop="copyrightHolder">Gary Gong</span>
</div>
  <div class="powered-by">由 <a href="https://hexo.io/" class="theme-link" rel="noopener" target="_blank">Hexo</a> & <a href="https://theme-next.org/" class="theme-link" rel="noopener" target="_blank">NexT.Gemini</a> 强力驱动
  </div>

        








      </div>
    </footer>
  </div>

  
  <script src="/lib/anime.min.js"></script>
  <script src="/lib/velocity/velocity.min.js"></script>
  <script src="/lib/velocity/velocity.ui.min.js"></script>

<script src="/js/utils.js"></script>

<script src="/js/motion.js"></script>


<script src="/js/schemes/pisces.js"></script>


<script src="/js/next-boot.js"></script>




  















  

  

</body>
</html>
